var express = require('express');
var connection = require('../util/mysqlConfig.js')
var router = express.Router();

/* GET home page. */
router.get('/', function(req, res, next) {
  res.render('index', { title: 'Express' });
});

router.get('/aaa',function(req,res){
  res.json({
    status:'ok!!!!'
  })
})

// router.get('/allMember',function(req,res){
//     let sql = 'select * from qyq_member'
//     connection.getConnection(function (err,connect) {
//         connect.query(sql,function (err,result,fields) {
//             res.json({
//                 data: {
//                   status: 'ok',
//                   result: result,
//                 }
//               })
//         })
//     })
//   })

module.exports = router;
